// 控制面版 上部帮助缩放操作函数
var help_topic_desc = "";				// 帮助实际内容
var help_topic_desc0 = " \
<div align='right' style='cursor: pointer; cursor: hand;line-height=150%;color:#999999' onclick='sw_help_topic()'> \
——点击此处，查阅更多内容介绍 \
&nbsp;&nbsp</div>";					// 帮助收缩后显示的内容
var help_topic_desc0_parameter = "";			// 帮助收缩后显示内容中的%%%%%%
var help_topic_title = "";				// 帮助title的内容
var help_topic_init = 0;				// 初始化帮助状态

//var help_particular_nav = "<br>　　如需了解有关“%%%%%%”更详细的信息，请单击<a target='blank' onclick='blur()' href='%%%URL%%%' title='%%%%%%'>这里</a>";	// 详细帮助导航
var help_particular_nav = "";
var help_particular_url = "";				// 详细帮助的URL
var help_particular_title = "";				// 详细帮助的title

var add_arr = new Array();
help_particular_url = "";
help_particular_url0 = "";

add_arr["/control/writing/explorer/article_list.php"] = help_particular_url + "161.html";
add_arr["/control/writing/explorer/article_list_sort.php"] = help_particular_url + "161.html";
add_arr["/control/writing/explorer/article_list_draft.php"] = help_particular_url + "161.html";
add_arr["/control/writing/explorer/article_list_recycle.php"] = help_particular_url + "161.html";

add_arr["/control/writing/article_class_manager.php"] = help_particular_url + "162.html";

add_arr["/control/comment/review_list.php"] = help_particular_url + "164.html";


add_arr["/control/blog/blog_set.php"] = help_particular_url + "156.html";
add_arr["/control/blog/blog_template.php"] = help_particular_url + "158.html";

add_arr["/control/section/wizard.php"] = help_particular_url + "159.html";
add_arr["/control/section/notice/notice_list.php"] = help_particular_url + "159.html";
add_arr["/control/section/notice/notice_add.php"] = help_particular_url + "159.html";
add_arr["/control/section/notice/notice_edit.php"] = help_particular_url + "159.html";
add_arr["/control/section/label/label_list.php"] = help_particular_url + "159.html";
add_arr["/control/section/label/label_add.php"] = help_particular_url + "159.html";
add_arr["/control/section/label/label_edit.php"] = help_particular_url + "159.html";
add_arr["/control/section/links/link_list.php"] = help_particular_url + "159.html";
add_arr["/control/section/links/link_add_title.php"] = help_particular_url + "159.html";
add_arr["/control/section/links/link_add_body.php"] = help_particular_url + "159.html";
add_arr["/control/section/links/link_edit.php"] = help_particular_url + "159.html";
add_arr["/control/section/links/link_edit_body.php"] = help_particular_url + "159.html";
add_arr["/control/section/special/special_list.php"] = help_particular_url + "159.html";
add_arr["/control/section/special/special_add_title.php"] = help_particular_url + "159.html";
add_arr["/control/section/special/special_add_body.php"] = help_particular_url + "159.html";
add_arr["/control/section/special/special_edit_body.php"] = help_particular_url + "159.html";
add_arr["/control/section/special/special_edit.php"] = help_particular_url + "159.html";
add_arr["/control/section/search/search_set.php"] = help_particular_url + "159.html";

add_arr["/control/member/base/modify_base.php"] = help_particular_url + "151.html";

add_arr["/control/member/raise/update_wizard.php"] = help_particular_url + "153.html";
add_arr["/control/member/raise/blog_update_succ.php"] = help_particular_url + "153.html";
add_arr["/control/member/raise/blog_update.php"] = help_particular_url + "153.html";
add_arr["/control/member/raise/blog_version.php"] = help_particular_url + "153.html";
add_arr["/control/member/raise/uhost_succ.php"] = help_particular_url + "153.html";
add_arr["/control/member/raise/uhost_register.php"] = help_particular_url + "153.html";

add_arr["/control/member/mobile/mobile_send.php"] = help_particular_url + "154.html";
add_arr["/control/member/mobile/mobile_check.php"] = help_particular_url + "154.html";
add_arr["/control/member/mobile/mobile_input.php"] = help_particular_url + "154.html";

add_arr["/control/member/base/myinfo_login.php"] = help_particular_url + "155.html";

add_arr["/control/album/blog/article_pic.php"] = help_particular_url + "165.html";
add_arr["/control/album/blog/article_pic_detail.php"] = help_particular_url + "165.html";
add_arr["/control/album/system/system_pic.php"] = help_particular_url + "165.html";

add_arr["/control/gbook/gbook_list.php"] = help_particular_url + "166.html";

add_arr["/control/blog/edit_my_index_add.php"] = help_particular_url + "159.html";


function sw_help_topic_init(title)
{
	var obj = document.getElementById("help_topic");
        var obj_icon = document.getElementById("help_topic_icon");

	help_topic_title = obj_icon.innerHTML;
	help_topic_desc = obj.innerHTML;
	help_topic_desc0_parameter = title;

	
	// 收缩后显示的内容
	help_topic_desc0 = help_topic_desc0.replace("%%%%%%", help_topic_desc0_parameter);

	
	// 帮助导航
	help_particular_nav = help_particular_nav.replace("%%%%%%", title);
	help_particular_nav = help_particular_nav.replace("%%%%%%", title);
	str_href= document.location.pathname;
	if (add_arr[str_href] == null)
	{
		// 当前页面没有帮助
		help_particular_nav = help_particular_nav.replace("%%%URL%%%", help_particular_url0);
	}
	else
	{
		// 当前页面有帮助
		help_particular_nav = help_particular_nav.replace("%%%URL%%%", add_arr[str_href]);
	}

//	alert(help_particular_nav);

	// 标题样式更新
	obj_icon.className = "help_topic_title";

	

	sw_help_topic_ex(help_topic_init);
}

function sw_help_topic()
{               
	var obj = document.getElementById("help_topic");
        var obj_icon = document.getElementById("help_topic_icon");

	if (obj.style.height == "20px")
	{
		b_status = 1;
	}	
	else
	{
		b_status = 0;
	}
	

	sw_help_topic_ex(b_status);
}

function sw_help_topic_ex(b_status)
{
	var obj = document.getElementById("help_topic");
        var obj_icon = document.getElementById("help_topic_icon");

        if (b_status == 1)
        {       
		// 打开
                obj_icon.innerHTML = "- " + help_topic_title;
                obj.style.height = "";
		obj.innerHTML = help_topic_desc + help_particular_nav;
		obj.className = "help_topic_desc";
        }       
        else
        {
		// 关闭
                obj_icon.innerHTML = "+ " + help_topic_title;
                obj.style.height = "20px";
		
		obj.innerHTML = help_topic_desc0;
		obj.className = "help_topic_desc_hidden";
        }

	try 
	{
		parent.iframeResize();       
	}
	catch(e)
	{
	}
}
